@echo off
:: ==============================================
:: GitHub File Downloader Script
:: Version: 1.0
:: Description: Automatic setup and launcher
:: ==============================================

:: Set console to UTF-8 for Unicode support
chcp 65001 >nul

:: Display welcome message
echo Starting GitHub File Downloader...

:: Check Python installation
where python >nul 2>&1
if %errorlevel% neq 0 (
    echo ERROR: Python not found
    echo Please install Python 3.6+ and add to system PATH
    pause
    exit /b 1
)

:: Install required Python packages
echo Installing required dependencies...
pip install -r requirements.txt
if %errorlevel% neq 0 (
    echo ERROR: Dependency installation failed
    echo Try manual installation: pip install -r requirements.txt
    pause
    exit /b 1
)

:: Launch application
echo Launching application...
python github_downloader.py

:: Keep console open after execution
pause